#include <iostream>
#include <iomanip>

using namespace std;

int main() {
    double a, b;
    cin >> a >> b;

    cout << fixed << setprecision(2) << 2 * a + 2 * b << endl;
    cout << fixed << setprecision(2) << a * b << endl;

    return 0;
}